const {db} = require("../util/util")

const addEventBoard = (event_id,board_id) => {//将候选人添加到该投票事件
  sql = "insert into event_board (event_id,board_id) values(?,?)";
  return db.execute(sql,[event_id,board_id]).then((data) => {
    return data[0].insertId;//判断是否插入成功
  })
}

module.exports = {addEventBoard}